function processed_x = low_pass1(x,w1,w2)
    a=ones(1,w1);
    b=ones(1,length(x)-w2);
    c=zeros(1,w2-w1);
    WIN = [a,c,b];
    win = iDFT(WIN,100,length(x));
    processed_x = conv(x,win);
    
    %绘制时域和频域图
    figure(3);
    
    subplot(211);
    stem(1:length(x),x(1:length(x)));
    axis([0,length(x),0,20]);
    title('处理前的时序信号');
    
    %忽略边缘效应
    subplot(212);
    stem(1:length(processed_x),processed_x(1:length(processed_x)));
    axis([0,length(processed_x),0,20]);
    title('处理后的时序信号');
end